import { Article, ArticleSchema } from '@ai/entity';
import { forwardRef, Module } from '@nestjs/common';
import { MongooseModule } from '@nestjs/mongoose';
import { ArticleCategoryModule } from '../article-category/article-category.module';
import { ArticleController } from './article.controller';
import { ArticleService } from './article.service';

@Module({
    imports: [
        forwardRef(() => ArticleCategoryModule),
        MongooseModule.forFeature([{ name: Article.name, schema: ArticleSchema }]),
    ],
    controllers: [ArticleController],
    providers: [ArticleService],
    exports: [ArticleService],
})
export class ArticleModule {}
